<!DOCTYPE html>
<html>
<head>
  <title>模板</title>
    <script type="text/javascript" src="../js/vue.js"></script>
    <link rel="stylesheet" type="text/css" href="../font/iconfont.css">
    <link href="https://cdn.jsdelivr.net/npm/animate.css@3.5.1" rel="stylesheet" type="text/css">
</head>
<body>
  <h1>template的三种模板</h1>
   <div id="demo">
       <p>{{message}}</p>
   </div>
   <template id="demo2">
     <h2 style="color: red">我是标签模板</h2>
   </template>
   <script type="x-template" id="demo3">
        <h2 style="color:red">我是script标签模板</h2>
    </script>
   <script type="text/javascript">
        var app = new Vue({
          el:"#demo",
          data:{
            message:"hello world",
          },
          // template:'#demo2',
          template:'#demo3',
          // template:`
          //   <h2 style="color: red">我是选项模板</h2>
          // `,
        })
   </script>
</body>
</html>